<?php
/**
 *  💡 免责声明：本软件不得用于商业用途，仅做学习交流
 *  ⚠️ 权利声明：本软件由版权人提供产品技术支持
 *  📅 项目编号：NX2025-0135
 */
namespace App\Admin\Actions\Row;

use App\Admin\Actions\Form\WithdrawalRejectForm;
use Dcat\Admin\Grid\RowAction;
use Dcat\Admin\Widgets\Modal;

class WithdrawalRejectAction extends RowAction
{
    protected $title = '&nbsp;&nbsp;❌ 驳回';

    public function render()
    {
        // 实例化表单类并传递自定义参数
        $form = WithdrawalRejectForm::make()->payload(['id' => $this->getKey()]);

        return Modal::make()
            ->xl()
            ->title($this->title)
            ->body($form)
            ->button($this->title);
    }
}
